import Vue from 'vue'
import VueRouter from 'vue-router'
import Home from '@/views/Home.vue'
import News from '@/views/News.vue'
import Sports from '@/views/Sports.vue'
import SportHome from '@/views/second/SportHome.vue'
import DomeSport from '@/views/second/DomeSport.vue'
import ForeSport from '@/views/second/ForeSport.vue'

Vue.use(VueRouter)

const router = new VueRouter({
  routes: [
    {
      path: '/home',
      component: Home,
    },
    {
      path: '/news',
      component: News,
    },
    {
      path: '/sports',
      component: Sports,
      children: [
        {
          path: 'sporthome',
          component: SportHome
        },
        {
          path: 'domesport',
          component: DomeSport
        },
        {
          path: 'foresport',
          component: ForeSport
        },
      ]
    },
  ]
})

export default router